import java.awt.BorderLayout;
import java.awt.Dimension;
import java.awt.GridLayout;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.JButton;
public class board {
	

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		
		JFrame frame = new JFrame("Battleship!");
		
		frame.setVisible(true);
		frame.setSize(700, 250);
		JPanel gametime = new JPanel();		
		JPanel yourfield = new JPanel();
		JPanel opponentfield = new JPanel();
		
		yourfield.setLayout(new GridLayout(10, 10));
		opponentfield.setLayout(new GridLayout(10, 10));
		
		yourfield.setSize(200, 200);
		opponentfield.setSize(200, 200);		
		
		opponentfield.setLocation(400, 0);
		
		JButton[] yourButtons = new JButton[100];
		JButton[] opponentButtons = new JButton[100];
		
		//adding buttons for ships
		for (int i = 0; i < 100; i++)	{					
			yourButtons[i] = new JButton();
			yourButtons[i].setPreferredSize(new Dimension(25, 10));
		}
		for (int i = 0; i < 100; i++)	{					
			yourfield.add(yourButtons[i]);
		}
		for (int i = 0; i < 100; i++)	{					
			opponentButtons[i] = new JButton();
			opponentButtons[i].setPreferredSize(new Dimension(25, 10));
			
		}
		for (int i = 0; i < 100; i++)	{					
			opponentfield.add(opponentButtons[i]);
		}
		
		
		yourfield.setVisible(true);
		opponentfield.setVisible(true);
		frame.setMinimumSize(new Dimension(700, 400));
		frame.add(yourfield, BorderLayout.WEST);
		frame.add(opponentfield, BorderLayout.EAST);
		
		
		
	}
	

}
